// 导入定义验证规则的包
const Joi = require("joi");
const title = Joi.string()
  .required()
const top_img = Joi.string()
  .required()
const inventory = Joi.string()
  .required()
const price = Joi.string()
  .required()
const start_time = Joi.string()
  .required()
const end_time = Joi.string()
  .required()
const id = Joi.number().empty([null, ""]).default("")
exports.reg_ip_schema = {
  body: {
    title,
    top_img,
    inventory,
    price,
    start_time,
    end_time,
    id
  },
};
const robId = Joi.number()
  .required()
exports.reg_rob_schema = {
  body: {
    ip_id: robId
  },
};